package com.demo.common.result;

import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor
public enum ResultCodeEnums {
    SUCCESS(200, "Success"),
    FAIL(500, "Failed"),

    SQL_ERROR(100, "SQL grammar error"),
    PARAM_ERROR(101, "Param error"),

    HTTP_STATUS_200(200, "OK"),
    HTTP_STATUS_400(400, "Request error"),
    HTTP_STATUS_401(401, "No authentication"),
    HTTP_STATUS_403(403, "No authorities"),
    HTTP_STATUS_500(500, "Server error");

    //属性
    private final int code;
    private final String message;
}
